<h1>Listing notes</h1>

<table>
  <tr>
    <th>Title</th>
    <th>Body</th>
  </tr>

<% for note in @notes %>
  <tr>
    <td><%=h note.title %></td>
    <td><%=h note.body %></td>
    <td><%= link_to 'Show', note %></td>
    <td><%= link_to 'Edit', edit_note_path(note) %></td>
    <td><%= link_to 'Destroy', note, :confirm => 'Are you sure?', :method => :delete %></td>
  </tr>
<% end %>
</table>

<br />

<%= link_to 'New note', new_note_path %>
